package com.scy.java.base;

import java.util.Scanner;

public class Demo06 {
//    if分支语句
    public static void main(String[] args) {
        //键盘录入票号
        System.out.println("请输入对应的座位号：");
        int num = new Scanner(System.in).nextInt();
        if (num >1 && num < 100) {//满足座位号条件
            //对座位号进行判断
            if (num % 2 ==0){
                System.out.println("座位号为偶数，坐右边");
            }else {
                System.out.println("座位号为奇数，坐左边");
            }
        }else {
            System.out.println("座位号不合法");
        }

    }
}
